NFC tag discovered
TagId: 0585921afb9100
TechList found with these entries:
android.nfc.tech.IsoDep
android.nfc.tech.NfcA
connection with card success

*********************************
************ step 00 ************
* our journey begins            *
*********************************
increase IsoDep timeout for long reading
timeout old: 2000 ms
timeout new: 10000 ms

*********************************
************ step 01 ************
* select PPSE                   *
*********************************
01 select PPSE command  length 20 data: 00a404000e325041592e5359532e444446303100
01 select PPSE response length 62 data: 6f3a840e325041592e5359532e4444463031a528bf0c2561234f07a0000000031010500a566973612044656269748701019f0a0800010501000000009000
------------------------------------
6F 3A -- File Control Information (FCI) Template
      84 0E -- Dedicated File (DF) Name
            32 50 41 59 2E 53 59 53 2E 44 44 46 30 31 (BINARY)
      A5 28 -- File Control Information (FCI) Proprietary Template
            BF 0C 25 -- File Control Information (FCI) Issuer Discretionary Data
                     61 23 -- Application Template
                           4F 07 -- Application Identifier (AID) - card
                                 A0 00 00 00 03 10 10 (BINARY)
                           50 0A -- Application Label
                                 56 69 73 61 20 44 65 62 69 74 (=Visa Debit)
                           87 01 -- Application Priority Indicator
                                 01 (BINARY)
                           9F 0A 08 -- [UNKNOWN TAG]
                                    00 01 05 01 00 00 00 00 (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------


*********************************
************ step 02 ************
* search applications on card   *
*********************************
02 analyze select PPSE response and search for tag 0x4F (applications on card)
Found tag 0x4F 1 time:
application Id (AID): a0000000031010


*********************************
************ step 03 ************
* select application by AID     *
*********************************
03 select application by AID a0000000031010 (number 1)

03 select AID command  length 13 data: 00a4040007a000000003101000
03 select AID response length 115 data: 6f6f8407a0000000031010a564500a566973612044656269749f120f636f6d6469726563742044656269749f1101018701015f2d046465656e9f38189f66049f02069f03069f1a0295055f2a029a039c019f3704bf0c1a9f0a0800010501000000009f5a053109780276bf6304df2001809000
------------------------------------
6F 6F -- File Control Information (FCI) Template
      84 07 -- Dedicated File (DF) Name
            A0 00 00 00 03 10 10 (BINARY)
      A5 64 -- File Control Information (FCI) Proprietary Template
            50 0A -- Application Label
                  56 69 73 61 20 44 65 62 69 74 (=Visa Debit)
            9F 12 0F -- Application Preferred Name
                     63 6F 6D 64 69 72 65 63 74 20 44 65 62 69 74 (=comdirect Debit)
            9F 11 01 -- Issuer Code Table Index
                     01 (NUMERIC)
            87 01 -- Application Priority Indicator
                  01 (BINARY)
            5F 2D 04 -- Language Preference
                     64 65 65 6E (=deen)
            9F 38 18 -- Processing Options Data Object List (PDOL)
                     9F 66 04 -- Terminal Transaction Qualifiers
                     9F 02 06 -- Amount, Authorised (Numeric)
                     9F 03 06 -- Amount, Other (Numeric)
                     9F 1A 02 -- Terminal Country Code
                     95 05 -- Terminal Verification Results (TVR)
                     5F 2A 02 -- Transaction Currency Code
                     9A 03 -- Transaction Date
                     9C 01 -- Transaction Type
                     9F 37 04 -- Unpredictable Number
            BF 0C 1A -- File Control Information (FCI) Issuer Discretionary Data
                     9F 0A 08 -- [UNKNOWN TAG]
                              00 01 05 01 00 00 00 00 (BINARY)
                     9F 5A 05 -- Terminal transaction Type (Interac)
                              31 09 78 02 76 (BINARY)
                     BF 63 04 -- [UNKNOWN TAG]
                              DF 20 01 -- [UNKNOWN TAG]
                                       80 (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------

get single data elements
single data retrieved from card
-----------------------------------------------------
applicationTransactionCounter: 00c2 (hex), 194 (dec)
-----------------------------------------------------
pinTryCounter: 01
-----------------------------------------------------
lastOnlineATCRegister: 0002
-----------------------------------------------------
logFormat: 9f27019f36029f02069f03069f1a025f2a0295059a039c01
-----------------------------------------------------


*********************************
************ step 04 ************
* search for tag 0x9F38         *
*********************************
04 search for tag 0x9F38 in the selectAid response

### processing the America Express, VisaCard and GiroCard path ###

found tag 0x9F38 (PDOL) in the selectAid with this length: 24 data: 9f66049f02069f03069f1a0295055f2a029a039c019f3704

The card is requesting 9 tags in the PDOL

Tag  Tag Name                        Length Value
-----------------------------------------------------
9f66 Terminal Transaction Qualifiers     4  27 00 00 00 
9f02 Amount, Authorised (Numeric)        6  00 00 00 00 10 00 
9f03 Amount, Other (Numeric)             6  00 00 00 00 00 00 
9f1a Terminal Country Code               2  09 78 
95   Terminal Verification Results (TVR) 5  00 00 00 00 00 
5f2a Transaction Currency Code           2  09 78 
9a   Transaction Date                    3  23 03 01 
9c   Transaction Type                    1  00 
9f37 Unpredictable Number                4  38 39 30 31 
-----------------------------------------------------


*********************************
************ step 05 ************
* get the processing options    *
*********************************
05 get the processing options  command length: 41 data: 80a8000023832127000000000000001000000000000000097800000000000978230301003839303100
05 get the processing options response length: 203 data: 7781c68202202094041001030057134871780082770574d25072211328662101000f9f100706011203a000009f2608ec1c5779ff2670379f2701809f360200c39f6c0204009f4b81809016903df9bad2d289d580a82ea1cf58d51d7ba234a7df6df83e4d115d93f31e8f98d95abdd8aac65c5b2fbcabaef5f7480fdf274eff4ffdab9e30e775660d4ffbf52629f2c63fdb93eb11cebaca3ac030e883bd864e3d19b8929119fe7d613529c106d0ae7270c4b645cc1f45e21c49c37f15f1686d949f367b11a6e731a97a9000
------------------------------------
77 81 C6 -- Response Message Template Format 2
         82 02 -- Application Interchange Profile
               20 20 (BINARY)
         94 04 -- Application File Locator (AFL)
               10 01 03 00 (BINARY)
         57 13 -- Track 2 Equivalent Data
               48 71 78 00 82 77 05 74 D2 50 72 21 13 28 66 21
               01 00 0F (BINARY)
         9F 10 07 -- Issuer Application Data
                  06 01 12 03 A0 00 00 (BINARY)
         9F 26 08 -- Application Cryptogram
                  EC 1C 57 79 FF 26 70 37 (BINARY)
         9F 27 01 -- Cryptogram Information Data
                  80 (BINARY)
         9F 36 02 -- Application Transaction Counter (ATC)
                  00 C3 (BINARY)
         9F 6C 02 -- Mag Stripe Application Version Number (Card)
                  04 00 (BINARY)
         9F 4B 81 80 -- Signed Dynamic Application Data
                     90 16 90 3D F9 BA D2 D2 89 D5 80 A8 2E A1 CF 58
                     D5 1D 7B A2 34 A7 DF 6D F8 3E 4D 11 5D 93 F3 1E
                     8F 98 D9 5A BD D8 AA C6 5C 5B 2F BC AB AE F5 F7
                     48 0F DF 27 4E FF 4F FD AB 9E 30 E7 75 66 0D 4F
                     FB F5 26 29 F2 C6 3F DB 93 EB 11 CE BA CA 3A C0
                     30 E8 83 BD 86 4E 3D 19 B8 92 91 19 FE 7D 61 35
                     29 C1 06 D0 AE 72 70 C4 B6 45 CC 1F 45 E2 1C 49
                     C3 7F 15 F1 68 6D 94 9F 36 7B 11 A6 E7 31 A9 7A (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------

workflow a)


*********************************
************ step 06 ************
* read files & search PAN       *
*********************************
06 read the files from card skipped
the response contains a Track 2 Equivalent Data tag [tag 0x57]
found tag 0x57 in the gpoResponse length: 19 data: 4871780082770574d25072211328662101000f
found a PAN 4871780082770574 with Expiration date: 2507


*********************************
************ step 07 ************
* print PAN & expire date       *
*********************************
07 get PAN and Expiration date from tag 0x57 (Track 2 Equivalent Data)
data for AID a0000000031010
PAN: 4871780082770574
Expiration date (YYMM): 2507

workflow c)
the response is of type 'Response Message Template Format 2' [tag 0x77]
found tag 0x77 in the gpoResponse
found 'AFL' [tag 0x94] in the response of type 'Response Message Template Format 2' [tag 0x77]
found tag 0x94 in the gpoResponse length: 4 data: 10010300

found this AFL data in the gpoResponse to read from: 10010300


*********************************
************ step 06 ************
* read files & search PAN       *
*********************************
06 read the files from card and search for PAN & Expiration date

The AFL contains 1 entry to read
for SFI 10 we read 3 records
readRecord  command length: 5 data: 00b2011400
readRecord response length: 256 data: 7081fb9081f85ab54faf4ad810b3cca4ed42c38e1e768fca3187ed1be4196c6779c4633cbe88751889c12b05e10ee87cb198518793ff61e87534f66850e96239b76648429eced4cc207608d0d2a932dd9e8c4bb0d139c4eca59e1ef5f4708f72d80dc5b66c45f4566c91b55384dfdeabb55faa622c6764cc9fb4c4900b6ab2cec5abad9057e2cf63a881bb4ec2a5d96634d7c11366eb908a168d33aa3c544822fc83e74c104b9275b2ef1cf41375b404a260bbf8fb3d4452af3d0630bb1ec2a01676ba588ae7820727622a6d9df5c93a3ce807d54b79ae007c3d401f8787dc3e235e8b9ae6b1b9279328cb1ca94105434010f15eb07f487f4d5c94f4a5a79000
------------------------------------
70 81 FB -- Record Template (EMV Proprietary)
         90 81 F8 -- Issuer Public Key Certificate
                  5A B5 4F AF 4A D8 10 B3 CC A4 ED 42 C3 8E 1E 76
                  8F CA 31 87 ED 1B E4 19 6C 67 79 C4 63 3C BE 88
                  75 18 89 C1 2B 05 E1 0E E8 7C B1 98 51 87 93 FF
                  61 E8 75 34 F6 68 50 E9 62 39 B7 66 48 42 9E CE
                  D4 CC 20 76 08 D0 D2 A9 32 DD 9E 8C 4B B0 D1 39
                  C4 EC A5 9E 1E F5 F4 70 8F 72 D8 0D C5 B6 6C 45
                  F4 56 6C 91 B5 53 84 DF DE AB B5 5F AA 62 2C 67
                  64 CC 9F B4 C4 90 0B 6A B2 CE C5 AB AD 90 57 E2
                  CF 63 A8 81 BB 4E C2 A5 D9 66 34 D7 C1 13 66 EB
                  90 8A 16 8D 33 AA 3C 54 48 22 FC 83 E7 4C 10 4B
                  92 75 B2 EF 1C F4 13 75 B4 04 A2 60 BB F8 FB 3D
                  44 52 AF 3D 06 30 BB 1E C2 A0 16 76 BA 58 8A E7
                  82 07 27 62 2A 6D 9D F5 C9 3A 3C E8 07 D5 4B 79
                  AE 00 7C 3D 40 1F 87 87 DC 3E 23 5E 8B 9A E6 B1
                  B9 27 93 28 CB 1C A9 41 05 43 40 10 F1 5E B0 7F
                  48 7F 4D 5C 94 F4 A5 A7 (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------

readRecord  command length: 5 data: 00b2021400
readRecord response length: 11 data: 70078f01099f3201039000
------------------------------------
70 07 -- Record Template (EMV Proprietary)
      8F 01 -- Certification Authority Public Key Index - card
            09 (BINARY)
      9F 32 01 -- Issuer Public Key Exponent
               03 (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------

readRecord  command length: 5 data: 00b2031400
readRecord response length: 240 data: 7081eb9f4681b02c4b62dfaede136b9bafeddebaaf41e5f4fdc9920b077817de896e6503c69c8f80ece2559cdf721ce1b7b2bc159fe77ec8d6eb45296876fbf4a6bd4bb4a11511ebd80fdf1c7bb8e1f4a2cdb7c4db0cc6f9fda7f6696c30d3846e1b98f4c849b7385f349d280fd92d75774dcbed96a5328f657f7eceb4bfa3ec3f9f39a64414bdbf0f03b15c49cbf0475bfa6a5f2513689c195faea031ae2391998be2028aa1671b380eb19a69a6c454bd2a30d11bc63c9f4701035a0848717800827705745f24032507315f3401015f280202769f070200809f4a01829f6e04207000009f690701859209cf04009000
------------------------------------
70 81 EB -- Record Template (EMV Proprietary)
         9F 46 81 B0 -- ICC Public Key Certificate
                     2C 4B 62 DF AE DE 13 6B 9B AF ED DE BA AF 41 E5
                     F4 FD C9 92 0B 07 78 17 DE 89 6E 65 03 C6 9C 8F
                     80 EC E2 55 9C DF 72 1C E1 B7 B2 BC 15 9F E7 7E
                     C8 D6 EB 45 29 68 76 FB F4 A6 BD 4B B4 A1 15 11
                     EB D8 0F DF 1C 7B B8 E1 F4 A2 CD B7 C4 DB 0C C6
                     F9 FD A7 F6 69 6C 30 D3 84 6E 1B 98 F4 C8 49 B7
                     38 5F 34 9D 28 0F D9 2D 75 77 4D CB ED 96 A5 32
                     8F 65 7F 7E CE B4 BF A3 EC 3F 9F 39 A6 44 14 BD
                     BF 0F 03 B1 5C 49 CB F0 47 5B FA 6A 5F 25 13 68
                     9C 19 5F AE A0 31 AE 23 91 99 8B E2 02 8A A1 67
                     1B 38 0E B1 9A 69 A6 C4 54 BD 2A 30 D1 1B C6 3C (BINARY)
         9F 47 01 -- ICC Public Key Exponent
                  03 (BINARY)
         5A 08 -- Application Primary Account Number (PAN)
               48 71 78 00 82 77 05 74 (NUMERIC)
         5F 24 03 -- Application Expiration Date
                  25 07 31 (NUMERIC)
         5F 34 01 -- Application Primary Account Number (PAN) Sequence Number
                  01 (NUMERIC)
         5F 28 02 -- Issuer Country Code
                  02 76 (NUMERIC)
         9F 07 02 -- Application Usage Control
                  00 80 (BINARY)
         9F 4A 01 -- Static Data Authentication Tag List
                  82 (BINARY)
         9F 6E 04 -- Visa Low-Value Payment (VLP) Issuer Authorisation Code
                  20 70 00 00 (BINARY)
         9F 69 07 -- UDOL
                  01 85 92 09 CF 04 00 (BINARY)
90 00 -- Command successfully executed (OK)
------------------------------------

found tag 0x5a in the readRecordResponse length: 8 data: 4871780082770574
found tag 0x5f24 in the readRecordResponse length: 3 data: 250731


*********************************
************ step 07 ************
* print PAN & expire date       *
*********************************
07 get PAN and Expiration date from tags 0x5a and 0x5f24
data for AID a0000000031010
PAN: 4871780082770574
Expiration date (YYMMDD): 250731

*********************************

*********************************
************ step 99 ************
* our journey ends              *
*********************************
